import { GET_CITY_LIST, GET_IMG_LIST } from "../actionType";

const initState = {
    cityList: [],
    swipeImg: []
}

const reducer = (state = initState, action) => {
    const { type, payload } = action
    switch (type) {
        case GET_CITY_LIST: return {
            ...state,
            cityList: payload
        }
        case GET_IMG_LIST: return {
            ...state,
            swipeImg: [...payload]
        }
        default: return {
            ...state
        }

    }
}
export default reducer;